R Map with "Play" Button
Simply press the "play" button to watch CO2 emissions change over time. Lighter countries depict less emissions as signified by the scale to the right.
Technical Design
A Plotly map with an adjustable slider was created from our dataset to develop another level of interactivity for users. In addition, hover text was integrated into the map to display country name and CO2 value in metric tons after the user chooses a year on the slider. The darker the red a country appear, the more CO2 emissions are emitted. The years are incremented by 6 years on the slider.
R Map
✔ Dpylr
✔ Plotly
✔ Htmlwidgets
A map with an "play" button was created in R from our dataset to develop a minimal, easy level of interactivity for users. This map is an example of a good basic interactive map. To develop the code, we used the "plot_geo" package in R paired with the following imports: dplyr, plotly, and htmlwidgets. After reading in the daaset, the map was crated with plot_geo and the folowing traces were defined to establish the characteristics: color, z, locations, and frame. Lastly, htmlwidgets is used to export the code as an HTML.